Skip to content

feat: enable static analysis#44

Merged
jeastham1993 merged 5 commits into
mainfrom
feat/enable-static-analysis
Jun 18, 2025
Merged

feat: enable static analysis#44
jeastham1993 merged 5 commits into
mainfrom
feat/enable-static-analysis

Conversation

@jeastham1993

Copy link
Copy Markdown
Collaborator

Enable .NET built in static analysis support and fix errors.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enables .NET built-in static analysis support while addressing various errors and refactoring code for improved consistency and maintainability. Key changes include updating API endpoint access modifiers and DTO naming conventions, replacing direct logger calls with unified Log methods, and integrating new code analysis configurations.

Reviewed Changes

Copilot reviewed 85 out of 85 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
Stickerlandia.UserManagement.Api/Program.cs Updated endpoint response types and logging configurations.
Stickerlandia.UserManagement.Api/Middlewares/GlobalExceptionHandler.cs Refactored error handling and logging to use shared Log methods.
Stickerlandia.UserManagement.Api/LoginEndpoint.cs Added null and input validations; modified access level to internal.
Stickerlandia.UserManagement.Api/GetUserDetailsEndpoint.cs Changed DTO type naming and access modifier adjustments.
Stickerlandia.UserManagement.Api/Configurations/RemoveSwaggerDefinitionsFilter.cs Removed duplicate schema removal calls for Swagger definitions.
Stickerlandia.UserManagement.Agnostic/UserManagementDbContext.cs Adjusted OnModelCreating for consistency and ensured null checks.
Stickerlandia.UserManagement.Agnostic/PostgresUserRepository.cs Introduced additional argument validations and improved logging.
Stickerlandia.UserManagement.Agnostic/MicrsoftIdentityAuthService.cs Applied null-coalescing for email and fixed potential null issues.
Stickerlandia.UserManagement.Agnostic/KafkaEventPublisher.cs Converted producer methods to async with improved error handling.
Stickerlandia.UserManagement.Agnostic/KafakStickerClaimedWorker.cs Updated dependency names and logging; see naming comment below.
Various build and configuration files Added static analysis configurations and updated project settings.
Comments suppressed due to low confidence (2)

user-management/src/Stickerlandia.UserManagement.Api/Program.cs:100

  • The DTO type was renamed from UserAccountDTO to UserAccountDto here; please ensure that this naming change is applied consistently across the codebase.
    .Produces<ApiResponse<UserAccountDto>>(200)

user-management/src/Stickerlandia.UserManagement.Agnostic/KafakStickerClaimedWorker.cs:1

  • The file and class name 'KafakStickerClaimedWorker' appears to contain a typo; consider renaming it to 'KafkaStickerClaimedWorker' for clarity and consistency.
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache License Version 2.0.

jeastham1993 and others added 2 commits June 17, 2025 21:24
…tions/RemoveSwaggerDefinitionsFilter.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

@scottgerring scottgerring left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jeastham1993 jeastham1993 merged commit 46378bf into main Jun 18, 2025
9 checks passed
@jeastham1993 jeastham1993 deleted the feat/enable-static-analysis branch June 18, 2025 10:15
jeastham1993 added a commit that referenced this pull request Jun 19, 2025
* feat: correct sticker-award to handle errors according to API spec

* feat: add AWS implementation and IaC

* Update user-management/infra/aws/lib/network.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* feat: update connection string

* chore: add labels to docker image

* chore: remove ASPNET Lambda hosting

* chore: add todos for future shared infra

* feat: enable static analysis (#44)

* feat: implement fixes from static analysis

* feat: add static analysis configuration

* feat: add static analysis configuration

* fix: remove duplicate .sln file

* Update user-management/src/Stickerlandia.UserManagement.Api/Configurations/RemoveSwaggerDefinitionsFilter.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Merge pull request #45 from DataDog/feat/add-datadog-to-docker

feat: add Datadog tracer to Dockerfiles

* feat(user-management): update docs (#37)

* chore: update OpenAPI docs

* chore: update README

* chore: add license and notice files

* chore: add dockerignore file

* Update user-management/src/Stickerlandia.UserManagement.Api/Configurations/RemoveSwaggerDefinitionsFilter.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update user-management/src/Stickerlandia.UserManagement.Api/Configurations/AuthorizeOperationFilter.cs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update user-management/README.md

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* chore: expand local dev and code structure docs

* chore: add cloud provider specific SLN files

* fix: specify .sln in dotnet restore

* chore: docs updates

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* feat: add AWS implementation and IaC

* feat: update connection string

* Update user-management/infra/aws/lib/network.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* chore: add labels to docker image

* chore: remove ASPNET Lambda hosting

* chore: add todos for future shared infra

* chore: fix static analysis for AWS impls

* feat: add arch diagram and README for AWS infra

---------

Co-authored-by: Scott Gerring <scott@scottgerring.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Scott Gerring <scottgerring@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants